#ifndef __I_LOCATION_OBJECT_H_INCLUDED__
#define __I_LOCATION_OBJECT_H_INCLUDED__

#include "IGameObject.h"
#include "vector3d.h"
namespace game
{
	namespace scene
	{
		struct SLocationObjectEntry : public SGameObjectEntry
		{
		public:
			//! Default constructor
			SLocationObjectEntry()
			{
			}

			//! Destructor
			virtual ~SLocationObjectEntry()
			{
			}
		};

		class ILocationObject : public IGameObject
		{
		public:
			ILocationObject(SLocationObjectEntry* entry, irr::scene::ISceneManager* sceneManager, game::video::IVideoHandler* videoHandler) 
				:	IGameObject(entry, sceneManager, videoHandler),
					TypedEntry(entry)
			{
				if(TypedEntry)
					TypedEntry->grab();
			}

			virtual ~ILocationObject()
			{
				if(TypedEntry)
					TypedEntry->drop();
			}
			
			virtual void addChild(IGameObject* child) = 0;

			//get current location
			
			//! Sets player current position
			virtual void setPlayerPosition(irr::core::vector3df value) = 0;

			//! Gets player current position
			virtual irr::core::vector3df getPlayerPosition() = 0;

		protected:
			irr::core::map<irr::core::stringc, ILocationObject*> ChildLocations;

			SLocationObjectEntry* TypedEntry;
		};
	}

}
#endif